﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace AudioRecorder
{
    public partial class player : Form
    {
        public player()
        {
            InitializeComponent();
        }
        public string src = "";
        private void button1_Click(object sender, EventArgs e)
        {
            OpenFileDialog fileDialog = new OpenFileDialog();

            fileDialog.Filter = "mp3|*.mp3";
            //fileDialog.ShowDialog();

            if (fileDialog.ShowDialog() == DialogResult.OK)
            {
                string name =fileDialog.FileName;

                MessageBox.Show(name);
            }



        }

        private void axWindowsMediaPlayer1_Enter(object sender, EventArgs e)
        {
            OpenFileDialog fileDialog = new OpenFileDialog();

            fileDialog.Filter = "mp3|*.mp3";
            //fileDialog.ShowDialog();

            if (fileDialog.ShowDialog() == DialogResult.OK)
            {
                string name = fileDialog.FileName;

                MessageBox.Show(name);
            }
        }

        private void player_Load(object sender, EventArgs e)
        {

            exetowinform fr = null;
            string exepath =src;
            splitContainer1.Panel1.Controls.Clear();
            fr = new exetowinform(splitContainer1.Panel1, "");
            fr.Start(exepath);

            // OpenFileDialog Oppf = new OpenFileDialog();
            // Oppf.ShowDialog();
            // if (Oppf.FileName != "")
            // {
            //     
            // }




        }

        private void player_Resize(object sender, EventArgs e)
        {
            
        }
    }
}
